-- *****************************************************************************
-- *                                                    *     _       _        *
-- *  AdaDecoupe                                        *    / \   __| | __ _  *
-- *  http://code.google.com/p/adadecoupe/              *   / _ \ / _` |/ _` | *
-- *  Radim Badsi & Célia Biguzzi - IG3                 *  / ___ \ (_| | (_| | *
-- *  Polytech'Montpellier                              * /_/   \_\__,_|\__,_| *
-- *                                                    *                      *
-- *****************************************************************************
-- *                                                                           *
-- * fsio.ads  -  FSIO                                                         *
-- * Sous-programmes d'entrée-sortie.                                          *
-- *                                                                           *
-- *****************************************************************************

with Ada.Text_Io;
with Ada.Integer_Text_Io;
with Ada.Float_Text_Io;
with Gnat.Awk; use Gnat.Awk;

with Util; use Util;

with Pieces;
with Commandes; with Liste_Commandes;
with Categories; with Liste_Categories;
with Plaques; with Liste_Plaques;
with Liste_Plaques_Finales;
with Plaques_Finales; with Emplacements;
with Statistiques;

package FSIO is
-- Permet de charger ou de sauver les divers fichiers selons leur format précis

    procedure Charger_Commandes (Path : in String; Liste_Comm : in out Liste_Commandes.T_Liste);
	procedure Sauver_Plan_Decoupe (Path : in String; L : in Liste_Plaques_Finales.T_Liste);
    procedure Sauver_Plaques_XML (Path : in String; L : in Liste_Plaques_Finales.T_Liste);
    procedure Sauver_Commandes (Path : in String; Liste_Comm : in out Liste_Commandes.T_Liste);
--    procedure Sauver_Commandes_Triees (Path : in String; Liste_Comm : in out Liste_Commandes.Liste.T_Liste);
	procedure Sauver_Commandes_Clients (Path : in String; Liste_Comm : in out Liste_Commandes.T_Liste);
    procedure Charger_Donnees_Generales (Path : in String);
    procedure Charger_Stock (Path : in String; Stock : in out Liste_Plaques.T_Liste);


private
    package Text_Io renames Ada.Text_Io;
    package Int_Io renames Ada.Integer_Text_Io;
    package Real_Io renames Ada.Float_Text_Io;

	generic
		with procedure Callback;
	procedure Parser (Path : in String);
	procedure Put_Natural (File: in out Text_Io.File_Type; N : in Natural; Largeur : in Natural := 0);
	


end FSIO;
